/*
 * @Author: username 1718324422@qq.com
 * @Date: 2022-11-28 09:08:54
 * @LastEditors: username 1718324422@qq.com
 * @LastEditTime: 2022-11-28 09:41:37
 * @FilePath: \xu_vue\src\router\routes.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import Vue from "vue";
import VueRouter from "vue-router";
import routes from "./routes";
Vue.use(VueRouter);
const router = new VueRouter({
  base: "/",
  routes,
});
//路由前置守卫
router.beforeEach((to, from, next) => {
  console.log(to.path, "1111");
  next();
});
export default router;
